package com.acme.bankapp.service.email;

import com.acme.bankapp.domain.email.Email;

public class EmailServiceTest {

	public static void main(String[] args) throws Exception {
		EmailService emailService = EmailService.getInstance();
		
		System.out.println("Adding mails to queue");
		for (int i = 0; i < 10; i++) {
			Email email = new Email(String.format("dummy email #%d", i), "admin@localhost");
			emailService.sendNotificationEmail(email);
		}
		System.out.println("Finished adding mails");
		
		emailService.close();
		System.out.println("EmailService closed");
	}

}
